package elephant.webserver;

import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import io.itit.itf.okhttp.FastHttpClient;

/**
 * 
 * @author icecooly
 *
 */
public class WebServerTestCase {
	//
	private static Logger logger=LoggerFactory.getLogger(WebServerTestCase.class);
	//
	public static void main(String[] args) {
		String url="http://skydu.cn/portal/education/news_info?id=1024";
		ExecutorService fixedThreadPool = Executors.newFixedThreadPool(10);  
		for(int i=0;i<10000000;i++){
			System.out.println(i);
			fixedThreadPool.execute(new Runnable() {
				@Override
				public void run() {
					try {
						FastHttpClient.get().url(url).build().execute();
					} catch (Exception e) {
						logger.error(e.getMessage(),e);
					}
				}
			});
		}  
	}
}
